<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"  
                xmlns:h="http://java.sun.com/jsf/html"  
                xmlns:f="http://java.sun.com/jsf/core"
                xmlns:p="http://primefaces.prime.com.tr/ui"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                template="./../templates/StaffTemplate.xhtml">

    <ui:define name="nav_menu">
        <p:menubar model="#{staffChangeInitialPasswordManagedBean.staffMenuModel}"/>
    </ui:define>
    <ui:define name="content">
            <h1>Search Result</h1>
            <p:panel header="Search Result">
                <p:dataTable var="stakeholder" value="#{stakeholderManagerBean.stakeholders}" dynamic="true" paginator="true" rows="5" emptyMessage="No Stakeholder">
                    <p:column sortBy="#{stakeholder.id}">
                        <f:facet name="header">
                            <h:outputText value="Stakeholder ID" />
                        </f:facet>
                        <h:outputText value="#{stakeholder.id}" />
                    </p:column>

                    <p:column sortBy="#{stakeholder.username}">
                        <f:facet name="header">
                            <h:outputText value="Stakeholder Username" />
                        </f:facet>
                        <h:outputText value="#{stakeholder.username}" />
                    </p:column>

                    <p:column sortBy="#{stakeholder.corpName}">
                        <f:facet name="header">
                            <h:outputText value="Stakeholder Corporation Name" />
                        </f:facet>
                        <h:outputText value="#{stakeholder.corpName}" />
                    </p:column>

                    <p:column sortBy="#{stakeholder.bizRegNumber}">
                        <f:facet name="header">
                            <h:outputText value="Stakeholder Business Registration Number" />
                        </f:facet>
                        <h:outputText value="#{stakeholder.bizRegNumber}" />
                    </p:column>

                    <p:column sortBy="#{stakeholder.address}">
                        <f:facet name="header">
                            <h:outputText value="Address" />
                        </f:facet>
                        <h:outputText value="#{stakeholder.address.streetName}" />
                    </p:column>

                    <p:column sortBy="#{stakeholder.corpContactNumber}">
                        <f:facet name="header">
                            <h:outputText value="Contact Number" />
                        </f:facet>
                        <h:outputText value="#{corpContactNumber}" />
                    </p:column>

                    <p:column sortBy="#{stakeholder.corpEmail}">
                        <f:facet name="header">
                            <h:outputText value="Email" />
                        </f:facet>
                        <h:outputText value="#{stakeholder.corpEmail}" />
                    </p:column>

                    <p:column sortBy="#{stakeholder.corpFaxNumber}">
                        <f:facet name="header">
                            <h:outputText value="Fax" />
                        </f:facet>
                        <h:outputText value="#{stakeholder.corpFaxNumber}" />
                    </p:column>
                </p:dataTable>
            </p:panel>
    </ui:define>
</ui:composition>

